package com.whfc.ms.api.hdc.service;

import com.whfc.common.exception.BizException;
import com.whfc.common.result.ListData;
import com.whfc.common.result.PageData;
import com.whfc.hdc.dto.AppDeviceUpgradeDTO;
import com.whfc.hdc.dto.AppDeviceUpgradePackageDTO;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * @Description:
 * @author: xugcheng
 * @version: 1.0
 * @date: 2020-12-25 15:23
 */
public interface MsUpgradeService {

    PageData<AppDeviceUpgradePackageDTO> upgradePackageList(Integer deviceType, Integer pageNum, Integer pageSize) throws BizException;

    /**
     * 添加升级包
     *
     * @param deviceType
     * @param masterVer
     * @param slaveVer
     * @param file
     */
    void addUpgradePackage(Integer deviceType, String masterVer, String slaveVer, MultipartFile file);

    void delUpgradePackage(Integer packageId) throws BizException;

    PageData<AppDeviceUpgradeDTO> upgradeDeviceList(Integer pageNum, Integer pageSize, Integer packageId, Integer state, String keyword) throws BizException;

    ListData<AppDeviceUpgradeDTO> upgradeDeviceList(Integer packageId) throws BizException;

    void addUpgradeDevice(Integer packageId, List<Integer> deviceIdList) throws BizException;

    void delUpgradeDevice(Integer upgradeId) throws BizException;
}
